package edu.byu.isys413.group1E.data;

/**
 * The super-class of all business objects in the program.
 *
 * @author Conan C. Albrecht
 */
public abstract class BusinessObject {
    
    boolean alreadyInDB = false;
    private String id = null;
    private boolean isDirty = false;
    
    /** Creates a new instance of BusinessObject */
    public BusinessObject() {
    }//constructor
    
    public String getId() {
        return id;
    }
    
    public void setId(String id) {
        this.id = id;
    }
    
    boolean isAlreadyInDB() {
        return alreadyInDB;
    }
    
    void setAlreadyInDB(boolean alreadyInDB) {
        this.alreadyInDB = alreadyInDB;
    }
    
    public boolean isIsDirty() {
        return isDirty;
    }
    
    public void setIsDirty(boolean isDirty) {
        this.isDirty = isDirty;
    }
    
    public void soil() {
        this.isDirty = true;
    }
    
    
    public void clean() {
        this.isDirty = false;
    }
    
}//class
